package strategy;

import strategy.improve.FlyBehavior;

/**
 * @Author liangliangzhao
 * @data 2023/4/21 10:35
 */

public abstract class Duck {
    //属性, 策略接口
    FlyBehavior flyBehavior;
    public Duck() {}
    public abstract void display();
    public void quack(){
        System.out.println("鸭子");
    }
    public void swim(){
        System.out.println("鸭子会游泳");
    }
    public void fly(){
        System.out.println("鸭子会飞翔");
    }
}
